package com.ssm.zookeeper.controller;

import com.ssm.zookeeper.feign.OrderFeign;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

@RestController
@ResponseBody
public class OrderController {

    //private Logger logger = LoggerFactory.getLogger(OrderController.class);

    @Autowired
    private OrderFeign orderFeign;

    @GetMapping("/order/get")
    public String get() {
        //logger.info("/order/get  +++++");
        return "get:ok";
    }

    @GetMapping("/order/save")
    public String save() {
        //logger.info("/order/save +++++");
        return "save:ok" + " |||  rpc invoke  ===> " + orderFeign.get();
    }
}
